/*
 * // +-------------------------------------------------------------------------------------------------
 * // |                 有你就好 [ 有节骨乃坚，无心品自端 ]     <http://encoding.wang>
 * // +-------------------------------------------------------------------------------------------------
 * // |                             独在异乡为异客         每逢佳节倍思亲
 * // +-------------------------------------------------------------------------------------------------
 * // |                 联系:   <707069100@qq.com>      <http://weibo.com/513778937>
 * // +-------------------------------------------------------------------------------------------------
 */

// -----------------------------------------------------------------------------------------------------
// +----------------------------------------------------------------------------------------------------
// |                   ErYang出品 属于小极品          共同学习    共同进步
// +----------------------------------------------------------------------------------------------------
// -----------------------------------------------------------------------------------------------------


package wang.encoding.mroot.admin.common.constant


import org.slf4j.Logger
import org.slf4j.LoggerFactory
import wang.encoding.mroot.model.entity.system.Config
import java.util.*

/**
 * 存放全局变量 主要用于可动态更新的配置
 *
 * @author ErYang
 */
object Global {


    private val logger: Logger = LoggerFactory.getLogger(Global::class.java)

    // -------------------------------------------------------------------------------------------------

    /**
     * 数据库配置
     */
    var CONFIG_MAP: Map<String, Config> = HashMap()

    // -------------------------------------------------------------------------------------------------

    /**
     * 根据 标识 得到数据库配置
     *
     * @param name 标识
     * @return 配置
     */
    fun getConfigByName(name: String): Config? {
        return Global.CONFIG_MAP[name]
    }

    // -------------------------------------------------------------------------------------------------

}

// -----------------------------------------------------------------------------------------------------

// End Global class

/* End of file Global.kt */
/* Location: ./src/main/kotlin/wang/encoding/mroot/admin/common/constant/Global.kt */

// -----------------------------------------------------------------------------------------------------
// +----------------------------------------------------------------------------------------------------
// |                           ErYang出品 属于小极品  O(∩_∩)O~~   共同学习    共同进步
// +----------------------------------------------------------------------------------------------------
// -----------------------------------------------------------------------------------------------------
